﻿<html>
    <head>
      <title>Products management</title>
      <meta http-equiv="content-type" content="text/html; charset=UTF-8"/>
      <meta name="viewport" content="width=device-width, initial-scale=1.0">      
      <meta name="keywords" content="website keywords, website keywords" />      
      <link href="style/layout.css?1.1" title="style" rel="stylesheet" type="text/css" />
      <link href="style/style.css?1.1" title="style" rel="stylesheet" type="text/css" />
      <link href="style/jquery-ui-1.8.17.custom.css" title="style" rel="stylesheet" type="text/css" />
      <link href="bootstrap/css/bootstrap.css?1.2" rel="stylesheet" type="text/css"/>
      <link href="bootstrap/css/bootstrap-responsive.css" rel="stylesheet"/>
      <script type="text/javascript" src="js/jquery.js"></script>      
      <script type="text/javascript" src="js/jquery.ui.datepicker-vi.js"></script>      
      <script type="text/javascript" src="js/jquery-ui-1.8.17.custom.min.js"></script>            
      <script type="text/javascript" src="js/login.js?1.1"></script>            
   </head>

   <body>
<header>
<section id="top-header-bar">
    <div class="row-fluid">              
      <h1><a href="index.php" class = "pull-left"> Trang web quản lý kho hàng</a></h1>                               
      <div id="user-info">
        <ul class="pull-right">
           <?php
           if (isset($_COOKIE['name'])) {
           ?> <li><?php echo $_COOKIE['name']; ?></li>                  
                 <li><a href="logout.php">Đăng xuất</a></li>					                      
                 <li><a href="changepw.php">Đổi mật khẩu</a></li>                  
           <?php
           } else {
           ?>
              <!-- Login box-->              
              <FORM action = "login.php" method = "POST" >
                    <li><input type="text" id = "user_login" name="user" value ="username"/></li>
                    <li><input type="password" id = "pass_login" name="pass" value="password"/></li>
                    <li><input type="submit" id = "submit_login" value="Login" /></li>
              </FORM>
           <?php
           }
           ?>       
      </ul>
      </div>
      
    </div>           
</section>
<nav id="nav">
<?php   
  if (isset($_COOKIE['type']))
    if ($_COOKIE['type'] == 2){?>         
    <div id="submenu" class="btn-toolbar ">
    <a class="btn btn-primary" href="nhap_hang.php">Nhập hàng</a>    
    <a class="btn btn-primary" href="hoa_don.php">Xuất hàng</a>
    <a class="btn btn-primary" href="print_code.php">In phiếu</a>
    <a class="btn btn-primary" href="thong_ke.php">Thống kê</a>         
    <a class="btn btn-primary" href="add_admin.php">Thêm người quản trị</a>      
    <a class="btn btn-primary" href="add_customer.php">Thêm khách hàng</a>      
    <a class="btn btn-primary" href="add_seller.php">Thêm người bán hàng</a>
    <a class="btn btn-primary" href="add_product.php">Thêm mã hàng</a>
    <a class="btn btn-primary" href="filter.php">Lọc hóa đơn</a>      
    </div>
 <?php }
 else if ($_COOKIE['type'] == 1){
  ?>
    <a class="btn btn-primary" href="hoa_don_seller.php">Nhập hóa đơn</a>
    <a class="btn btn-primary" href="edit_hoa_don.php">Sửa hóa đơn</a>
    <?php
 }
  ?>
</nav>
</header>

<section id="main">    
    <div id="content">

    